<!-- 购买记录 -->
<script lang="ts">
export default {
  name: "yybureauFormation",
};
</script>
<template>
  <div class="page-box h100 display-flex czbj">
    <p class="title-label mb10">
      购买记录
    </p>
    <div>
      <dxtable :headBtn="headBtn" :dataJson="dataJson" :portUrl="portUrl" :qx="qx" ref="databale"
        sonRouter="yybureauFormationBJ"></dxtable>
    </div>
  </div>
  <n-modal v-model:show="showModal" preset="card" class="dsfsdrewrewe" >
    <template #header>
      <div>浏览二维码</div>
    </template>
    <div>
      <img :src="qcosertt" class="fsdfereertr">
    </div>
    <template #action>
      <div class="tr">
        <n-button @click="showModal=false"> 关闭 </n-button>
      </div>
    </template>
  </n-modal>
</template>
<script lang='ts' setup>
import dxtable from "../../../components/util/dxtable.vue";
import sort from "../../../components/util/sort.vue";
import { dxget, dxpost, qurl, hf } from "../../../util/index";
import { h, ref, reactive, onBeforeUpdate, render } from "vue";
const props = defineProps({
  pup: { type: String },
});
const showModal = ref(false)
const qcosertt = ref()
let portUrl = "yuyue/adminapi/useryyjsjl";
let headBtn = [];
const zdList = ref()
const databale = ref();
const videourl = ref()
const typeli = ref([])
const initeer = () => {
  databale.value.initDataExpose();
};
const emit = defineEmits(["callBack"]);
// 弹窗公用该列表
let dataJson = reactive([
  {
    title: "id",
    key: "id",
    width: 50,
  },
  {
    title: "参加人昵称",
    key: "mynicc",
    width: 240,
  }, 
  {
    title: "技师昵称",
    key: "nickname",
  }, 
  {
    title: "预约时间",
    key: "",
    width: 240,
    render(row) {
        return row.yudfcdfa +' '+row.yudfcdfb+'-'+row.yudfcdfc
    },
  },  
  {
    title: "预约项目",
    key: "yudfcdfd",
  },  
  {
    title: "接单时间",
    key: "orderReceivingTime",
  },  
  {
    title: "开始服务时间",
    key: "servicingTime",
  },   {
    title: "结束服务时间",
    key: "endService",
  },

  {
    title: "报名费用",
    key: "paymentAmount",
    render(row) {
        return "￥" + row.paymentAmount
    },
  },
  
  
  
  {
    title: "状态",
    key: "orderStatus",
    width:100,
    render(row) {
     let jnxs = ""
       switch (row.orderStatus) {
         case 0: jnxs="待支付"; break;
         case 1: jnxs="待接单"; break;
         case 2: jnxs="待服务"; break;
         case 3: jnxs="进行中"; break;
         case 4: jnxs="已完成"; break;
         case 5: jnxs="已取消"; break;
       }
       return jnxs
    }
  },{
    title: "添加时间",
    key: "addTime",
  },
  
]);

const qx = {
 DeletePermissionID: "yyserviceSetup", //删除
};
const getcasetype = async () => {
  const { data }: any = await dxget("dxgjAdmin/getzd", { name: 'yyzjfl' })

  dataJson[5].options = [
    {
      label: "全部",
      value: ""
    },
    ...data
  ]
  typeli.value = data
  // ishjwoer.value = true
}
getcasetype()

</script>
<style scoped>
.fsdfereertr{
  width: 100%;
  height: 360px;
}
</style>
  
  
  